package org.webArchi.common.api.domain;

import javax.persistence.*;
import java.io.Serializable;
import java.util.Date;

/**
 * @author amith jayasekara
 * Embeddable address class for maintain user contact info.
 */
@Entity
@Table(name = "TPNUMBERS", schema = "COMMON")
public class TPNumber implements Serializable {

    public enum State {
        INACTIVE, // 0
        ACTIVE,// 1 -
    }

    @Id
    @Column(nullable = false)
    private Long tpNumber;

    @Column (nullable = false)
    private Date purchaseDate;

    @Column(nullable = false, columnDefinition = "smallint not null default 1")
    private  State state;

    public Long getTpNumber() {
        return tpNumber;
    }

    public void setTpNumber(Long tpNumber) {
        this.tpNumber = tpNumber;
    }

    public Date getPurchaseDate() {
        return purchaseDate;
    }

    public void setPurchaseDate(Date purchaseDate) {
        this.purchaseDate = purchaseDate;
    }

    public State getState() {
        return state;
    }

    public void setState(State state) {
        this.state = state;
    }

}
